import { Get, Inject } from '@midwayjs/core';
import { CoolController, BaseController } from '@cool-midway/core';
import { StoreStoreEntity } from '../../entity/store';
import { StoreStoreService } from '../../service/store';

/**
 * 店家信息
 */
@CoolController({
  api: ['add', 'delete', 'update', 'info', 'list', 'page'],
  entity: StoreStoreEntity,
  service: StoreStoreService,
})
export class AppStoreStoreController extends BaseController {
  @Inject()
  storeStoreService: StoreStoreService;

  /**
   * 其他接口
   */
  @Get('/test')
  async test() {
    return this.ok(await this.storeStoreService.test());
  }
}